package com.kj.xuyuan.adapter;

import android.widget.ImageView;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.kj.xuyuan.R;
import com.kj.xuyuan.http.UrlConstants;
import com.kj.xuyuan.model.VipListBean;
import com.kj.xuyuan.util.GlideUtils;

import java.util.List;

import androidx.annotation.Nullable;

public class TopicListAdapter extends BaseQuickAdapter<VipListBean, BaseViewHolder> {

    public TopicListAdapter() {
        super(R.layout.item_dynamic_top);
    }

    @Override
    protected void convert(BaseViewHolder helper, VipListBean item) {
        helper.setText(R.id.tv_content,item.getTitle());
        ImageView ivBg = helper.getView(R.id.iv_bg);
        GlideUtils.loadRoundImage(mContext, ivBg,UrlConstants.Base_Http+item.getCover_image(),8,R.mipmap.ic_error);
    }
}
